package com.hxd.otc.module.wallet.adapter;

import android.support.v4.app.Fragment;
import android.support.v4.app.FragmentManager;
import android.support.v4.app.FragmentPagerAdapter;

import com.hxd.otc.base.BaseRecyclerFragment;

import java.util.List;


/**
 * Created by alphabet on 2018/5/30.
 */

public class BodyPagerAdapter extends FragmentPagerAdapter {
  private List<BaseRecyclerFragment> fragments;

  public BodyPagerAdapter(FragmentManager fm, List<BaseRecyclerFragment> fragments) {
    super(fm);
    this.fragments = fragments;
  }

  @Override public Fragment getItem(int position) {
    return fragments.get(position);
  }

  @Override public int getCount() {
    return fragments.size();
  }
}
